﻿#parse("partials/header.html") #parse("partials/sidebar.html")
<script type="text/javascript">
    $(document).ready(function () {
        var oTable = $('#datalist').dataTable({
            "sScrollX": "150%",
            "bScrollCollapse": true,
            "bSort": false,
            "bAutoWidth": false,
            "sPaginationType": "full_numbers",
            "bProcessing": true,
            "bServerSide": true,

            "sAjaxSource": rooturl + "master/doctors/tablelist",
            "aoColumns": [
                            { "mDataProp": "Id" },
                            { "mDataProp": "DoctorCode" },
                            { "mDataProp": "DoctorName" },
                            { "mDataProp": "Specialist" },
                            { "mDataProp": "GroupSpecialist" }
            //{ "mDataProp": "Address" }
                        ],
            "aoColumnDefs": [
                                {
                                    "fnRender": function (o) {
                                        return "<center> <a class='tooltip' title='Edit Record' href='/master/doctors/editdoctor/?id=" + o.aData['Id'] + "' ><img src='/images/Icons/pencil.png'/></a> <a class='confirm button delete tooltip' title='Delete Record' confirmdelete='Are you want to delete this record?' href='/master/doctors/deletedoctor/?id=" + o.aData['Id'] + "'><img src='/images/Icons/eraser.png'/></a></center>";
                                    },
                                    "aTargets": [0]
                                }
                        ],
            "fnServerData": function (sSource, aoData, fnCallback) {
                aoData.push({ "name": "IdHospital", "value": $('#IdHospital').val() });
                aoData.push({ "name": "IdGroupSpecialist", "value": $('#IdSpecialist').val() });
                aoData.push({ "name": "TextBoxSpecialist", "value": $('#TextBoxSpecialist').val() });
                aoData.push({ "name": "TextBoxSubSpecialist", "value": $('#TextBoxSubSpecialist').val() });
                jQuery.ajax({
                    "dataType": 'json',
                    "type": "GET",
                    "url": rooturl + "master/doctors/tablelist",
                    "data": aoData,
                    "success": fnCallback

                });
            }
        });



        $('#buttonSearch').click(function () { oTable.fnDraw(); });


    });


</script>
<style>
    div#datalist_filter 
    {
        display:none;
    }
    div#datalist_length 
    {
        display:none;
    }
    .mws-table thead 
    {
        margin-top:-10px;
    }
</style>
<div id="mws-container" class="clearfix">
    <div class="container">
        <div class="mws-panel grid_8">
            <div class="mws-panel-header">
                <span class="mws-i-24 i-table-1">$Pagetitle</span>
            </div>
            <div class="mws-panel-body">
                <div class="mws-panel-toolbar top clearfix">
                    <ul>
                        <li><a class="mws-ic-16 ic-accept" href="/admins/specialist/createspecialist" title="Accept">Add Specialist</a></li>
                        <li><a class="mws-ic-16 ic-accept" href="/admins/specialist" title="Accept">List Specialist</a></li>
                    </ul>
                </div>
                <table cellpadding="0" cellspacing="0" border="0" class="mws-table" id="datalist"
                    width="100%">
                    <thead>
                        <tr>
                            <th style="width: 100px; text-align: center">
                                Actions
                            </th>
                            <th style="text-align: center">
                                Specialist Name
                            </th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td colspan="7" class="dataTables_empty">
                                <img src="../../../Images/Admin/252.gif" />
                            </td>
                        </tr>
                    </tbody>
                </table>
            </div>
        </div>
        <hr />
    </div>
#parse("partials/footer.html")
